<%@ page contentType="text/html;charset=UTF-8" language="java" pageEncoding="utf-8" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
		<meta name="renderer" content="webkit">
		<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
		<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
		<link rel="stylesheet" href="./static/layui/css/layui.css">
	</head>
	<body>
		<form class="layui-form" action="courierupdate.do" method="post" onsubmit="return testphonenum()">
			<div class="layui-form-item" hidden>
				<label class="layui-form-label" >id</label>
				<div class="layui-input-block">
					<input type="text" name="id" lay-verify="title" autocomplete="off" placeholder="请输入用户名"
						   class="layui-input"  value="${courier.id}">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">姓名</label>
				<div class="layui-input-block">
					<input type="text" name="couriername" lay-verify="title" autocomplete="off" placeholder="请输入姓名"
						class="layui-input" readonly value="${courier.couriername}">
				</div>
			</div>
			<div class="layui-form-item">
				<label class="layui-form-label">配置状态</label>
				<div class="layui-input-block">
					${courier.status}
					<c:choose>
						<c:when test="${courier.status ge '配送中'}">
							<input type="radio" name="status" value="空闲中" title="空闲中" >
							<input type="radio" name="status" value="配送中" title="配送中" checked="">
						</c:when>
						<c:when test="${courier.status ge '空闲中'}">
							<input type="radio" name="status" value="空闲中" title="空闲中" checked="">
							<input type="radio" name="status" value="配送中" title="配送中">
						</c:when>
					</c:choose>
				</div>
			</div>
			<div class="layui-form-item">
				<div class="layui-inline">
					<label class="layui-form-label">手机号</label>
					<div class="layui-input-inline">
						<input type="tel" name="phonenum" placeholder="请输入手机号"
							autocomplete="off" class="layui-input" value="${courier.phonenum}"  id="phonenum">
					</div>
				</div>
			</div>
			<div class="layui-form-item">
				<div class="layui-input-block">
					<button type="submit" class="layui-btn" lay-submit="" lay-filter="demo1">立即提交</button>
					<button type="reset" class="layui-btn layui-btn-primary">重置</button>
				</div>
			</div>
		</form>
	</body>
	<script type="text/javascript" src="./static/layui/layui.js"></script>
	<script type="text/javascript" src="./static/js/jquery-3.4.1.min.js"></script>
	<script type="text/javascript" src="./static/js/testphonenum.js"></script>
	<script>
		layui.use(['form', 'layedit', 'laydate'], function() {
			var form = layui.form,
				layer = layui.layer,
				layedit = layui.layedit,
				laydate = layui.laydate;

			
			//创建一个编辑器
			var editIndex = layedit.build('LAY_demo_editor');

			//监听提交
			// form.on('submit(demo1)', function(data) {
			//
			// });
		});
	</script>
</html>
